package edu.unh.sustain;

import java.net.MalformedURLException;
import java.net.URL;

public class Video {

    private String title;
    private String description;
    private URL    url;

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public URL getUrl() {
        return url;
    }

    public void setUrl(URL url) {
        this.url = url;
    }

    public void setUrl(String url) throws MalformedURLException {
        this.url = new URL(url);
    }

    public Video copy() {
        Video copy = new Video();
        copy.setDescription(this.description);
        copy.setTitle(this.title);
        copy.setUrl(this.url);

        return copy;
    }
}
